<?php

namespace Shop\AdminBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * Orders
 *
 * @ORM\Table(name="orders")
 * @ORM\Entity(repositoryClass="Shop\AdminBundle\Entity\OrdersRepository")
 */
class Orders
{
    /**
     * @var string
     *
     * @ORM\Column(name="sn", type="string", length=40, nullable=false)
     */
    private $sn;

    /**
     * @var string
     *
     * @ORM\Column(name="sn_hash", type="string", length=32, nullable=false)
     */
    private $snHash;

    /**
     * @var string
     *
     * @ORM\Column(name="payment_key", type="string", length=128, nullable=false)
     */
    private $paymentKey;

    /**
     * @var integer
     *
     * @ORM\Column(name="user_id", type="integer", nullable=false)
     */
    private $userId;

    /**
     * @var integer
     *
     * @ORM\Column(name="product_id", type="integer", nullable=false)
     */
    private $productId;

    /**
     * @var integer
     *
     * @ORM\Column(name="create_time", type="integer", nullable=false)
     */
    private $createTime;

    /**
     * @var integer
     *
     * @ORM\Column(name="pay_time", type="integer", nullable=false)
     */
    private $payTime;

    /**
     * @var boolean
     *
     * @ORM\Column(name="status", type="boolean", nullable=false)
     */
    private $status;

    /**
     * @var integer
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="IDENTITY")
     */
    private $id;

    /**
     * @var
     * @ORM\Column(type="smallint", columnDefinition="tinyint", nullable=false)
     */
    private $isDelete;



    /**
     * Set sn
     *
     * @param string $sn
     * @return Orders
     */
    public function setSn($sn)
    {
        $this->sn = $sn;

        return $this;
    }

    /**
     * Get sn
     *
     * @return string 
     */
    public function getSn()
    {
        return $this->sn;
    }

    /**
     * Set snHash
     *
     * @param string $snHash
     * @return Orders
     */
    public function setSnHash($snHash)
    {
        $this->snHash = $snHash;

        return $this;
    }

    /**
     * Get snHash
     *
     * @return string 
     */
    public function getSnHash()
    {
        return $this->snHash;
    }

    /**
     * Set paymentKey
     *
     * @param string $paymentKey
     * @return Orders
     */
    public function setPaymentKey($paymentKey)
    {
        $this->paymentKey = $paymentKey;

        return $this;
    }

    /**
     * Get paymentKey
     *
     * @return string 
     */
    public function getPaymentKey()
    {
        return $this->paymentKey;
    }

    /**
     * Set userId
     *
     * @param integer $userId
     * @return Orders
     */
    public function setUserId($userId)
    {
        $this->userId = $userId;

        return $this;
    }

    /**
     * Get userId
     *
     * @return integer 
     */
    public function getUserId()
    {
        return $this->userId;
    }

    /**
     * Set productId
     *
     * @param integer $productId
     * @return Orders
     */
    public function setProductId($productId)
    {
        $this->productId = $productId;

        return $this;
    }

    /**
     * Get productId
     *
     * @return integer 
     */
    public function getProductId()
    {
        return $this->productId;
    }

    /**
     * Set createTime
     *
     * @param integer $createTime
     * @return Orders
     */
    public function setCreateTime($createTime)
    {
        $this->createTime = $createTime;

        return $this;
    }

    /**
     * Get createTime
     *
     * @return integer 
     */
    public function getCreateTime()
    {
        return $this->createTime;
    }

    /**
     * Set payTime
     *
     * @param integer $payTime
     * @return Orders
     */
    public function setPayTime($payTime)
    {
        $this->payTime = $payTime;

        return $this;
    }

    /**
     * Get payTime
     *
     * @return integer 
     */
    public function getPayTime()
    {
        return $this->payTime;
    }

    /**
     * Set status
     *
     * @param boolean $status
     * @return Orders
     */
    public function setStatus($status)
    {
        $this->status = $status;

        return $this;
    }

    /**
     * Get status
     *
     * @return boolean 
     */
    public function getStatus()
    {
        return $this->status;
    }

    /**
     * Get id
     *
     * @return integer 
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set isDelete
     *
     * @param integer $isDelete
     * @return Orders
     */
    public function setIsDelete($isDelete)
    {
        $this->isDelete = $isDelete;

        return $this;
    }

    /**
     * Get isDelete
     *
     * @return integer 
     */
    public function getIsDelete()
    {
        return $this->isDelete;
    }
}
